﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage/MasterPage.master" AutoEventWireup="true"
    CodeFile="SCGY.aspx.cs" Inherits="ServicesSheet_SCGY" %>

<%@ Register Assembly="ZLTextBox" Namespace="BaseText" TagPrefix="cc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="Titile" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="head" runat="Server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="Content" runat="Server">
    <infolight:webdatasource id="Master" runat="server" autoapply="True" webdatasetid="WMaster"
        datamember="Services_SCGY" cachedataset="True">
    </infolight:webdatasource>
    <infolight:webdatasource id="WEmp" runat="server" selectalias="Usasdb" selectcommand="SELECT     &#13;&#10;Employees.EmployeeID, &#13;&#10;Employees.EmpName, &#13;&#10;CompanyJob.JobName, &#13;&#10;Department.DepartmentName&#13;&#10;FROM         &#13;&#10;Employees INNER JOIN&#13;&#10;                      Department ON Employees.DepartmentId = Department.DepartmentId                   INNER JOIN&#13;&#10;                      CompanyJob ON Employees.JobId = CompanyJob.JobId&#13;&#10;WHERE     (Employees.EmpStatus = 1)"
        cachedataset="True">
    </infolight:webdatasource>
    <infolight:webdefault id="WebDefault1" runat="server" datamember="Services_SCGY"
        datasourceid="Master">
        <fields>
                <InfoLight:DefaultFieldItem DefaultValue="-1" FieldName="Id" />
                <InfoLight:DefaultFieldItem DefaultValue="_Today" FieldName="UDate" />
                <InfoLight:DefaultFieldItem DefaultValue="GetEmpId()" FieldName="EmployeeId" />
            </fields>
    </infolight:webdefault>
    <FLTools:FLWebNavigator ID="FLWebNavigator1" runat="server" BindingObject="wfvMaster"
        ShowDataStyle="FormViewStyle" StatusStrip="WebStatusStrip1" CtlHeight="25" CssClass="NavigatorBar"
        Width="100%" oncommand="FLWebNavigator1_Command">
        <NavControls>
            <infolight:controlitem controlname="Add" controltext="add" controltype="Image" controlvisible="True"
                disenableimageurl="../Image/UIPics/Add3_C.gif" imageurl="../Image/UIPics/Add_C.gif"
                mouseoverimageurl="../Image/UIPics/Add2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="Update" controltext="update" controltype="Image"
                controlvisible="True" disenableimageurl="../Image/UIPics/Edit3_C.gif" imageurl="../Image/UIPics/Edit_C.gif"
                mouseoverimageurl="../Image/UIPics/Edit2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="Delete" controltext="delete" controltype="Image"
                controlvisible="True" disenableimageurl="../Image/UIPics/Delete3_C.gif" imageurl="../Image/UIPics/Delete_C.gif"
                mouseoverimageurl="../Image/UIPics/Delete2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="Apply" controltype="Image" controlvisible="True"
                disenableimageurl="../Image/UIPics/Apply3_C.gif" imageurl="../Image/UIPics/Apply_C.gif"
                mouseoverimageurl="../Image/UIPics/Apply2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="Abort" controltype="Image" controlvisible="True"
                disenableimageurl="../Image/UIPics/Abort3_C.gif" imageurl="../Image/UIPics/Abort_C.gif"
                mouseoverimageurl="../Image/UIPics/Abort2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="Query" controltext="query" controltype="Image"
                controlvisible="True" disenableimageurl="../image/uipics/Query3_C.gif" imageurl="../image/uipics/Query_C.gif"
                mouseoverimageurl="../image/uipics/Query2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="Submit" controltext="submit" controltype="Image"
                controlvisible="True" disenableimageurl="" imageurl="../image/uipics/Submit_C.gif"
                mouseoverimageurl="../image/uipics/Submit2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="Approve" controltext="approve" controltype="Image"
                controlvisible="True" disenableimageurl="" imageurl="../Image/UIPics/Approve_C.gif"
                mouseoverimageurl="../Image/UIPics/Approve2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="Return" controltext="return" controltype="Image"
                controlvisible="True" disenableimageurl="" imageurl="../image/uipics/Return_C.gif"
                mouseoverimageurl="../image/uipics/Return2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="Reject" controltext="reject" controltype="Image"
                controlvisible="True" disenableimageurl="" imageurl="../image/uipics/Reject_C.gif"
                mouseoverimageurl="../image/uipics/Reject2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="Notify" controltext="notify" controltype="Image"
                controlvisible="True" disenableimageurl="" imageurl="../image/uipics/Notify_C.gif"
                mouseoverimageurl="../image/uipics/Notify2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="FlowDelete" controltext="flowdelete" controltype="Image"
                controlvisible="True" disenableimageurl="" imageurl="../image/uipics/FlowDelete_C.gif"
                mouseoverimageurl="../image/uipics/FlowDelete2_C.gif" size="70">
            </infolight:controlitem>
            <infolight:controlitem controlname="Plus" controltext="plus" controltype="Image"
                controlvisible="True" disenableimageurl="" imageurl="../image/uipics/Plus_C.gif"
                mouseoverimageurl="../image/uipics/Plus2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="Pause" controltext="pause" controltype="Image"
                controlvisible="True" disenableimageurl="" imageurl="../image/uipics/Pause_C.gif"
                mouseoverimageurl="../image/uipics/Pause2_C.gif" size="48">
            </infolight:controlitem>
            <infolight:controlitem controlname="Comment" controltext="comment" controltype="Image"
                controlvisible="True" disenableimageurl="" imageurl="../image/uipics/Comment_C.gif"
                mouseoverimageurl="../image/uipics/Comment2_C.gif" size="48">
            </infolight:controlitem>
        </NavControls>
        <NavStates>
            <infolight:webnavigatorstateitem enablecontrols="First;Previous;Next;Last;Add;Update;Delete;Query;Print;Export"
                statetext="Initial">
            </infolight:webnavigatorstateitem>
            <infolight:webnavigatorstateitem enablecontrols="First;Previous;Next;Last;Add;Update;Delete;Query;Print;Export"
                statetext="Browsed">
            </infolight:webnavigatorstateitem>
            <infolight:webnavigatorstateitem enablecontrols="OK;Cancel;Apply;Abort" statetext="Inserting">
            </infolight:webnavigatorstateitem>
            <infolight:webnavigatorstateitem enablecontrols="OK;Cancel;Apply;Abort" statetext="Editing">
            </infolight:webnavigatorstateitem>
            <infolight:webnavigatorstateitem enablecontrols="" statetext="Applying">
            </infolight:webnavigatorstateitem>
            <infolight:webnavigatorstateitem enablecontrols="First;Previous;Next;Last;Add;Update;Delete;Apply;Abort;Export"
                statetext="Changing">
            </infolight:webnavigatorstateitem>
            <infolight:webnavigatorstateitem enablecontrols="" statetext="Querying">
            </infolight:webnavigatorstateitem>
            <infolight:webnavigatorstateitem enablecontrols="" statetext="Printing">
            </infolight:webnavigatorstateitem>
            <infolight:webnavigatorstateitem enablecontrols="" statetext="Normal">
            </infolight:webnavigatorstateitem>
            <infolight:webnavigatorstateitem enablecontrols="Add" statetext="Insert">
            </infolight:webnavigatorstateitem>
            <infolight:webnavigatorstateitem enablecontrols="Update" statetext="Modify">
            </infolight:webnavigatorstateitem>
            <infolight:webnavigatorstateitem enablecontrols="Query" statetext="Inquery">
            </infolight:webnavigatorstateitem>
            <infolight:webnavigatorstateitem enablecontrols="Query;Update" statetext="Prepare">
            </infolight:webnavigatorstateitem>
        </NavStates>
        <FLStates>
            <FLTools:FLWebNavigatorStateItem StateText="Approve" VisibleControls="Approve;Return;Notify;Comment" />
            <FLTools:FLWebNavigatorStateItem StateText="Continue" VisibleControls="Submit;Notify;Comment" />
            <FLTools:FLWebNavigatorStateItem StateText="Inquery" VisibleControls="Comment" />
            <FLTools:FLWebNavigatorStateItem StateText="Notify" VisibleControls="Notify;FlowDelete;Comment" />
            <FLTools:FLWebNavigatorStateItem StateText="Return" VisibleControls="Submit;Reject;Notify" />
            <FLTools:FLWebNavigatorStateItem StateText="Submit" VisibleControls="Submit;Notify;Pause" />
            <FLTools:FLWebNavigatorStateItem StateText="None" VisibleControls="" />
            <FLTools:FLWebNavigatorStateItem StateText="Plus" VisibleControls="Approve;Notify;Comment" />
            <FLTools:FLWebNavigatorStateItem StateText="Lock" VisibleControls="Notify" />
            <FLTools:FLWebNavigatorStateItem StateText="FSubmit" VisibleControls="Submit;Notify" />
            <FLTools:FLWebNavigatorStateItem StateText="RSubmit" VisibleControls="Submit;Return;Notify" />
        </FLStates>
    </FLTools:FLWebNavigator>
    <infolight:webformview id="wfvMaster" runat="server" backcolor="Silver" bordercolor="White"
        borderstyle="Groove" borderwidth="2px" cellpadding="4" datasourceid="Master"
        forecolor="#333333" layoutcolnum="2" ondatabound="wfvMaster_DataBound" width="100%"
        oniteminserting="wfvMaster_ItemInserting" onitemupdating="wfvMaster_ItemUpdating">
        <footerstyle backcolor="#507CD1" font-bold="True" forecolor="White" />
        <editrowstyle backcolor="LightCyan" forecolor="Blue" />
        <rowstyle backcolor="#EFF3FB" forecolor="Navy" />
        <pagerstyle backcolor="PowderBlue" forecolor="White" horizontalalign="Center" />
        <headerstyle backcolor="#507CD1" font-bold="True" forecolor="White" />
        <insertrowstyle backcolor="LightCyan" forecolor="Blue" />
        <edititemtemplate>
                <table class="container_table">
                    <tr>
                        <td>
                            <asp:Label ID="CaptionId" runat="server" Text="用车编码:" Width="67px"></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="IdTextBox" runat="server" ReadOnly="True" Text='<%# Bind("Id") %>'
                                Width="120px"></asp:TextBox>
                        </td>
                        <td>
                            <asp:Label ID="CaptionUDate" runat="server" Text="日期:"></asp:Label></td>
                        <td>
                        
                                           
<asp:TextBox ID="ZLTextBox1" runat="server" onfocus="WdatePicker({dateFmt:'yyyy-M-d'})" 
                                Text='<%# Bind("UDate", "{0:d}") %>' CssClass="Wdate" Width="120px"/></asp:TextBox>

</td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="CaptionEmployeeId" runat="server" Text="员工工号:"></asp:Label></td>
                        <td>
                            <InfoLight:WebRefVal ID="WebRefVal1" runat="server" AllowAddData="False" BindingText=""
                                BindingValue='<%# Bind("EmployeeId") %>' ButtonImageUrl="../Image/refval/RefVal.gif"
                                DataBindingField="EmployeeId" DataSourceID="WEmp" DataTextField="EmpName" DataValueField="EmployeeID"
                                MultiLanguage="False" PostBackButonClick="False" ReadOnly="True" ResxDataSet=""
                                ResxFilePath="" UpdatePanelID="" UseButtonImage="True" Width="120px">
                            </InfoLight:WebRefVal>
                        </td>
                        <td>
                            <asp:Label ID="CaptionDepartmentName" runat="server" Text="部门名称:" Width="68px"></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="DepartmentNameTextBox" runat="server" ReadOnly="True" Text='<%# Bind("DepartmentName") %>'
                                Width="120px"></asp:TextBox>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="CaptionPeopleCount" runat="server" Text="乘车总人数目:" Width="86px"></asp:Label></td>
                        <td>
                            <cc1:ZLTextBox ID="ZLTextBox2" runat="server" FloatLength="2" InputType="number"
                                IsDisplayTime="False" Language="Chinese" onblurCssName="" onfocus="calendar()"
                                onfocusCssName="" ShowMessage="" Text='<%# Bind("PeopleCount") %>' textValue=""
                                Width="120px"></cc1:ZLTextBox></td>
                        <td>
                            <asp:Label ID="CaptionClient" runat="server" Text="客户有否:"></asp:Label></td>
                        <td>
                            <asp:CheckBox ID="ClientCheckBox" runat="server" Checked='<%# Bind("Client") %>'
                                Width="133px" /></td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="CaptionCause" runat="server" Text="用车事由:"></asp:Label></td>
                        <td colspan="3">
                            <asp:TextBox ID="CauseTextBox" runat="server" Height="69px" Text='<%# Bind("Cause") %>'
                                TextMode="MultiLine" Width="437px"></asp:TextBox>
                            &nbsp;</td>
                    </tr>
                </table>
            </edititemtemplate>
        <insertitemtemplate>
                <table class="container_table">
                    <tr>
                        <td>
                            <asp:Label ID="CaptionId" runat="server" Text="用车编码:" Width="67px"></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="IdTextBox" runat="server" ReadOnly="True" Text='<%# Bind("Id") %>'
                                Width="120px"></asp:TextBox>
                        </td>
                        <td>
                            <asp:Label ID="CaptionUDate" runat="server" Text="日期:"></asp:Label></td>
                        <td>
                        
                       
<asp:TextBox ID="ZLTextBox1" runat="server" onfocus="WdatePicker({dateFmt:'yyyy-M-d'})" 
                                Text='<%# Bind("UDate", "{0:d}") %>' CssClass="Wdate" Width="120px"/></asp:TextBox>
                           </td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="CaptionEmployeeId" runat="server" Text="员工工号:"></asp:Label></td>
                        <td>
                            <InfoLight:WebRefVal ID="WebRefVal1" runat="server" AllowAddData="False" BindingText=""
                                BindingValue='<%# Bind("EmployeeId") %>' ButtonImageUrl="../Image/refval/RefVal.gif"
                                DataBindingField="EmployeeId" DataSourceID="WEmp" DataTextField="EmpName" DataValueField="EmployeeID"
                                MultiLanguage="False" PostBackButonClick="False" ReadOnly="True" ResxDataSet=""
                                ResxFilePath="" UpdatePanelID="" UseButtonImage="True" Width="120px">
                            </InfoLight:WebRefVal>
                        </td>
                        <td>
                            <asp:Label ID="CaptionDepartmentName" runat="server" Text="部门名称:" Width="68px"></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="DepartmentNameTextBox" runat="server" ReadOnly="True" Text='<%# Bind("DepartmentName") %>'
                                Width="120px"></asp:TextBox>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="CaptionPeopleCount" runat="server" Text="乘车总人数目:" Width="86px"></asp:Label></td>
                        <td>
                            <cc1:ZLTextBox ID="ZLTextBox2" runat="server" FloatLength="2" InputType="number"
                                IsDisplayTime="False" Language="Chinese" onblurCssName="" onfocus="calendar()"
                                onfocusCssName="" ShowMessage="" Text='<%# Bind("PeopleCount") %>' textValue=""
                                Width="120px"></cc1:ZLTextBox></td>
                        <td>
                            <asp:Label ID="CaptionClient" runat="server" Text="客户有否:"></asp:Label></td>
                        <td>
                            <asp:CheckBox ID="ClientCheckBox" runat="server" Checked='<%# Bind("Client") %>'
                                Width="133px" /></td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="CaptionCause" runat="server" Text="用车事由:"></asp:Label></td>
                        <td colspan="3">
                            <asp:TextBox ID="CauseTextBox" runat="server" Height="69px" Text='<%# Bind("Cause") %>'
                                TextMode="MultiLine" Width="437px"></asp:TextBox>
                            &nbsp;</td>
                    </tr>
                </table>
            </insertitemtemplate>
        <itemtemplate>
                <table class="container_table">
                    <tr>
                        <td>
                            <asp:Label ID="CaptionId" runat="server" Text="用车编码:" Width="67px"></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="IdTextBox" runat="server" ReadOnly="True" Text='<%# Bind("Id") %>'
                                Width="120px"></asp:TextBox>
                        </td>
                        <td>
                            <asp:Label ID="CaptionUDate" runat="server" Text="日期:"></asp:Label></td>
                        <td>
                            <cc1:ZLTextBox ID="ZLTextBox1" runat="server" Enabled="False" FloatLength="2" InputType="date"
                                IsDisplayTime="False" Language="Chinese" onblurCssName="" onfocus="calendar()"
                                onfocusCssName="" ShowMessage="" Text='<%# Bind("UDate", "{0:yyyy-MM-dd}") %>'
                                textValue="" Width="120px"></cc1:ZLTextBox></td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="CaptionEmployeeId" runat="server" Text="员工工号:"></asp:Label></td>
                        <td>
                            <InfoLight:WebRefVal ID="WebRefVal1" runat="server" AllowAddData="False" BindingText=""
                                BindingValue='<%# Bind("EmployeeId") %>' ButtonImageUrl="../Image/refval/RefVal.gif"
                                DataBindingField="EmployeeId" DataSourceID="WEmp" DataTextField="EmpName" DataValueField="EmployeeID"
                                MultiLanguage="False" PostBackButonClick="False" ReadOnly="True" ResxDataSet=""
                                ResxFilePath="" UpdatePanelID="" UseButtonImage="True" Width="120px">
                            </InfoLight:WebRefVal>
                        </td>
                        <td>
                            <asp:Label ID="CaptionDepartmentName" runat="server" Text="部门名称:" Width="68px"></asp:Label>
                        </td>
                        <td>
                            <asp:TextBox ID="DepartmentNameTextBox" runat="server" ReadOnly="True" Text='<%# Bind("DepartmentName") %>'
                                Width="120px"></asp:TextBox>
                        </td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="CaptionPeopleCount" runat="server" Text="乘车总人数目:" Width="86px"></asp:Label></td>
                        <td>
                            <cc1:ZLTextBox ID="ZLTextBox2" runat="server" Enabled="False" FloatLength="2" InputType="number"
                                IsDisplayTime="False" Language="Chinese" onblurCssName="" onfocus="calendar()"
                                onfocusCssName="" ShowMessage="" Text='<%# Bind("PeopleCount") %>' textValue=""
                                Width="120px"></cc1:ZLTextBox></td>
                        <td>
                            <asp:Label ID="CaptionClient" runat="server" Text="客户有否:"></asp:Label></td>
                        <td>
                            <asp:CheckBox ID="ClientCheckBox" runat="server" Checked='<%# Bind("Client") %>'
                                Width="133px" /></td>
                    </tr>
                    <tr>
                        <td>
                            <asp:Label ID="CaptionCause" runat="server" Text="用车事由:"></asp:Label></td>
                        <td colspan="3">
                            <asp:TextBox ID="CauseTextBox" runat="server" Height="69px" ReadOnly="True" Text='<%# Bind("Cause") %>'
                                TextMode="MultiLine" Width="437px"></asp:TextBox>
                            &nbsp;</td>
                    </tr>
                </table>
            </itemtemplate>
        <fields>
                <InfoLight:FormViewField ControlID="IdTextBox" FieldName="Id" />
                <InfoLight:FormViewField ControlID="ZLTextBox1" FieldName="UDate" />
                <InfoLight:FormViewField ControlID="WebRefVal1" FieldName="EmployeeId" />
            </fields>
    </infolight:webformview>
</asp:Content>
